﻿<ResourceDictionary
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" 
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:local="using:Microsoft.ALMRangers.VsarTreasureMap.WindowsStoreApp.Views.Controls"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    mc:Ignorable="d">
    
    <Style TargetType="local:RollOverIsland">
        <Setter Property="Background" Value="{StaticResource ButtonBackgroundThemeBrush}" />
        <Setter Property="Foreground" Value="{StaticResource ButtonForegroundThemeBrush}" />
        <Setter Property="BorderBrush" Value="{StaticResource ButtonBorderThemeBrush}" />
        <Setter Property="BorderThickness" Value="{StaticResource ButtonBorderThemeThickness}" />
        <Setter Property="Padding" Value="12,4,12,4" />
        <Setter Property="HorizontalAlignment" Value="Left" />
        <Setter Property="VerticalAlignment" Value="Center" />
        <Setter Property="FontFamily" Value="{StaticResource ContentControlThemeFontFamily}" />
        <Setter Property="FontWeight" Value="SemiBold" />
        <Setter Property="FontSize" Value="{StaticResource ControlContentThemeFontSize}" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="local:RollOverIsland">
                    <Grid>
                		<VisualStateManager.VisualStateGroups>
                			<VisualStateGroup x:Name="CommonStates">
                				<VisualState x:Name="PointerOver">
                					<Storyboard>
                						<ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)" Storyboard.TargetName="standardImage">
                							<DiscreteObjectKeyFrame KeyTime="0">
                								<DiscreteObjectKeyFrame.Value>
                									<Visibility>Collapsed</Visibility>
                								</DiscreteObjectKeyFrame.Value>
                							</DiscreteObjectKeyFrame>
                						</ObjectAnimationUsingKeyFrames>
                						<ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)" Storyboard.TargetName="rolloverImage">
                							<DiscreteObjectKeyFrame KeyTime="0">
                								<DiscreteObjectKeyFrame.Value>
                									<Visibility>Visible</Visibility>
                								</DiscreteObjectKeyFrame.Value>
                							</DiscreteObjectKeyFrame>
                						</ObjectAnimationUsingKeyFrames>
                					</Storyboard>
                				</VisualState>
                				<VisualState x:Name="Normal">
                					<Storyboard>
                						<ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)" Storyboard.TargetName="rolloverImage">
                							<DiscreteObjectKeyFrame KeyTime="0">
                								<DiscreteObjectKeyFrame.Value>
                									<Visibility>Collapsed</Visibility>
                								</DiscreteObjectKeyFrame.Value>
                							</DiscreteObjectKeyFrame>
                						</ObjectAnimationUsingKeyFrames>
                						<ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)" Storyboard.TargetName="standardImage">
                							<DiscreteObjectKeyFrame KeyTime="0">
                								<DiscreteObjectKeyFrame.Value>
                									<Visibility>Visible</Visibility>
                								</DiscreteObjectKeyFrame.Value>
                							</DiscreteObjectKeyFrame>
                						</ObjectAnimationUsingKeyFrames>
                					</Storyboard>
                				</VisualState>
                				<VisualState x:Name="Pressed">
                					<Storyboard>
                						<ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)" Storyboard.TargetName="standardImage">
                							<DiscreteObjectKeyFrame KeyTime="0">
                								<DiscreteObjectKeyFrame.Value>
                									<Visibility>Collapsed</Visibility>
                								</DiscreteObjectKeyFrame.Value>
                							</DiscreteObjectKeyFrame>
                						</ObjectAnimationUsingKeyFrames>
                						<ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)" Storyboard.TargetName="rolloverImage">
                							<DiscreteObjectKeyFrame KeyTime="0">
                								<DiscreteObjectKeyFrame.Value>
                									<Visibility>Visible</Visibility>
                								</DiscreteObjectKeyFrame.Value>
                							</DiscreteObjectKeyFrame>
                						</ObjectAnimationUsingKeyFrames>
                					</Storyboard>
                				</VisualState>
                				<VisualState x:Name="Disabled"/>
                			</VisualStateGroup>
                			<VisualStateGroup x:Name="FocusStates">
                				<VisualState x:Name="Unfocused"/>
                				<VisualState x:Name="Focused">
                					<Storyboard>
                						<ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)" Storyboard.TargetName="rolloverImage">
                							<DiscreteObjectKeyFrame KeyTime="0">
                								<DiscreteObjectKeyFrame.Value>
                									<Visibility>Visible</Visibility>
                								</DiscreteObjectKeyFrame.Value>
                							</DiscreteObjectKeyFrame>
                						</ObjectAnimationUsingKeyFrames>
                						<ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)" Storyboard.TargetName="standardImage">
                							<DiscreteObjectKeyFrame KeyTime="0">
                								<DiscreteObjectKeyFrame.Value>
                									<Visibility>Collapsed</Visibility>
                								</DiscreteObjectKeyFrame.Value>
                							</DiscreteObjectKeyFrame>
                						</ObjectAnimationUsingKeyFrames>
                					</Storyboard>
                				</VisualState>
                				<VisualState x:Name="PointerFocused"/>
                			</VisualStateGroup>
                		</VisualStateManager.VisualStateGroups>
                		<Image x:Name="standardImage" Source="{TemplateBinding StandardImage}"/>
                		<Image x:Name="rolloverImage" Source="{TemplateBinding RolloverImage}" Visibility="Collapsed"/>
                		<ContentPresenter />
                	</Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

</ResourceDictionary>
